<?php #//AJAX PHP PENNY AUCTION v.1.3

#///////////////////////////////////////////////////////////
#//  COPYRIGHT 2009 Aaron Helmlinger ALL RIGHTS RESERVED  //
#///////////////////////////////////////////////////////////
                        include "../includes/config.inc.php";
             
                             include "loggedin.inc.php";
                 
                               
          if($_POST[update])  {

       
       $homepage_announcement1 = $_POST[homepage_announcement];
                    $live_auction_announcement1 = $_POST[live_auction_announcement];           
    
$query2="UPDATE PHPAUCTIONXL_version_1_3 SET homepage_announcement='$homepage_announcement1' WHERE id='1'";
       
mysql_query($query2);

$query2="UPDATE PHPAUCTIONXL_version_1_3 SET live_auction_announcement='$live_auction_announcement1' WHERE id='1'";
       
mysql_query($query2);
       
         }     
       
         $query_settings = "select * from PHPAUCTIONXL_version_1_3 where id='1'";
                             $query_settings2 =  mysql_query ($query_settings);
                                $homepage_announcement2 = mysql_result($query_settings2,0,"homepage_announcement");
                                  $homepage_announcement2 = ltrim($homepage_announcement2);
                               
                               $live_auction_announcement2 = mysql_result($query_settings2,0,"live_auction_announcement");
                                     $live_auction_announcement2 = ltrim($live_auction_announcement2);              
                                
      $ERR =$MSG_AJAX_ADMIN_HOMEPAGE_ANNOUNCEMENTS_ERROR;
  ?>
  






<HTML>
<HEAD>
<link rel='stylesheet' type='text/css' href='style.css' />
<link href="css/main.css" rel="stylesheet" type="text/css">
</HEAD>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">





<table width="100%" border="0" cellpadding="0" cellspacing="0">
  <tr> 
    <td>
    
       <? // -------------------------- Admin Tool Heading --------------------------------------?>
       
       
    <table width="100%" border="0" cellspacing="0" cellpadding="0" class="titulo">
        <tr> 

          
   <td class="icono"><img src="images/graph_icon2.gif" width="30" height="26"></td>              
                    <td class="breadcrumbs"><p><span><?=$MSG_25_0009?></span>&nbsp;&gt;&gt;&nbsp;<? print $MSG_AJAX_ADMIN_HOMEPAGE_ANNOUNCEMENTS_TITLE; ?></p></td>
              </tr>
      </table>
      
      
      
      </td>
  </tr>
  <tr>
    <td align="center" valign="middle">&nbsp;</td>
  </tr>
    <tr> 
    <td align="center" valign="middle">
    
    
    
<TABLE BORDER=0 WIDTH=100% CELLPADDING=0 CELLSPACING=0 BGCOLOR="#FFFFFF">
<TR>
<TD align="center">
<BR>
<FORM NAME=conf ACTION=<?=basename($_SERVER['PHP_SELF'])?> METHOD=POST>


  <? // -------------------------- LIGHT BLUE TITLE BAR --------------------------------------?>

	<TABLE WIDTH="95%" BORDER="0" CELLSPACING="0" CELLPADDING="0"  class="base" ALIGN="CENTER" style="border:1px solid #ccc;">
		<TR>
			<TD ALIGN=CENTER class=title>
				<p><? print $MSG_AJAX_ADMIN_HOMEPAGE_ANNOUNCEMENTS_TITLE; ?></p>
			</TD>
		</TR>
		
		
		
		<TR>
		<TD>
		
    
    
    <TABLE WIDTH=100% ALIGN="CENTER" CELLPADDING=0 cellspacing="0" BGCOLOR="#FFFFFF">
		
 <? // -------------------------- ERROR BAR --------------------------------------?>    
 
 <? if ($ERR) { ?>   
    	<TR>
				<TD COLSPAN="2"  class="error"><B>
					<p><BLINK><FONT size=+2><? print $ERR; ?> ALSO, Everytime You Save The Content, A Space Is Added To The Beginning Of Each Content Box, Be Sure To Not Let This Space Buildup Or It Will Begin To Delete Your Content.</font></BLINK></p>
					</B></TD>
			</TR>
	<? } ?>	
    
    	<TR>
			
			
 <? // -------------------------- WHITE BAR --------------------------------------?> 			
				<TD WIDTH="125"> 
				<p class="blue"><? print $MSG_AJAX_ADMIN_HOMEPAGE_ANNOUNCEMENTS_LABEL1; ?></p>
					</TD>
				<TD WIDTH="405">
					<TEXTAREA NAME="homepage_announcement" 
   ROWS="5" COLS="100">
              <? print $homepage_announcement2; ?>
   </textarea><BR><? print $MSG_AJAX_ADMIN_HOMEPAGE_ANNOUNCEMENTS_NOTE1; ?> 
</TD>
			</TR>
			
		 <? // -------------------------- GREY BAR --------------------------------------?>	
			
			<TR>
				<TD WIDTH="125" class="gris">
					<p class="blue"><? print $MSG_AJAX_ADMIN_HOMEPAGE_ANNOUNCEMENTS_LABEL2; ?></p>
					</TD>
				<TD WIDTH="405" class="gris">
						<TEXTAREA NAME="live_auction_announcement" 
   ROWS="5" COLS="100">
              <? print $live_auction_announcement2; ?>
   </textarea><BR><? print $MSG_AJAX_ADMIN_HOMEPAGE_ANNOUNCEMENTS_NOTE2; ?></TD>
			</TR>
			
			
			</TABLE>
		
		  <INPUT TYPE=hidden NAME=update VALUE=1 >
		        <INPUT TYPE="submit" NAME="act" VALUE="<? print $MSG_AJAX_ADMIN_UPDATE_SETTINGS; ?>" class="action">
		 </form>
		
		</TD>
		</TR>
	</TABLE>
</TD>
</TR>
</TABLE>
</TD>
</TR>
</TABLE>
</BODY>
</HTML>
